﻿using Newtonsoft.Json.Linq;
using System.IO;

namespace Sparklings.Gui
{
    public class LevelMetaData : ChoiceListElement
    {
        public LevelMetaData(string fileName)
        {
            JObject levelJson = JObject.Parse(File.ReadAllText(fileName));
            Name = (string)levelJson["name"];
            FilePath = fileName;
        }
        public string Name;
        public string FilePath;
        public string GetText()
        {
            return Name;
        }
    }
}
